package com.wxg.rpc;

import com.wxg.common.core.dao.mysql.website.User;
import com.wxg.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by void on 2019/6/12.
 */
@RestController
public class UserRpc {

    @Autowired
    private UserService userService;

    /**
     * 通过用户名查询
     * @param userName
     * @return
     */
    @GetMapping("/rpc/user/queryByUserName")
    public User queryByUserName(String userName){
        return userService.queryByUserName(userName);
    }
}
